package com.grademaster.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.grademaster.entity.Classes;
import com.grademaster.vo.ClassVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
* @author Administrator
* @description 针对表【classes(班级表)】的数据库操作Mapper
* @createDate 2024-06-25 13:56:47
* @Entity generator.domain.Classes
*/
@Mapper
public interface ClassesMapper extends BaseMapper<Classes> {
    /**
     * 根据教师ID查询班级名称
     * @param teacherId
     * @return
     */
    List<String> selectDistinctClassNamesByTeacherId(@Param("teacherId") String teacherId);

    /**
     * 根据条件查询班级信息
     * @param gradeName
     * @param majorName
     * @param className
     * @param page
     * @param pageSize
     * @return
     */
    List<ClassVO> selectClassesByCondition(String gradeName, String majorName, String className, int page, int pageSize);

    /**
     * 根据条件查询班级数量
     * @param gradeName
     * @param majorName
     * @param className
     * @return
     */
    int countClassesByCondition(String gradeName, String majorName, String className);
}




